class Solution
{
public:
    int removePalindromeSub(string s)
    {
        int front = 0;
        int back = s.size() - 1;
        while (front < back)
        {
            if (s[front] != s[back])
            {
                return 2;
            }
            ++front;
            --back;
        }
        return 1;
    }
};